package com.exam.system.dao;

import com.exam.system.entity.ExamInfo;
import com.exam.system.entity.ExamPaper;
import com.exam.system.entity.ExamType;
import com.exam.system.entity.ExamUser;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @Description 用户dao层
 * @versions 1.0
 */
public interface ExamInfoDao {
    List<ExamInfo> findAll();

    List<ExamInfo>  selectByTypeId(Integer examTypeId);

    List<ExamInfo>  selectByExamName(ExamInfo examInfo);

    List<ExamInfo>  selectByBeginTime(@Param("beginTime") String beginTime);
    //根据类型查询
    List<ExamInfo>  selectByExamTypeId(ExamInfo examInfo);
    //根据主键查看单个考试信息
    ExamInfo selectByPrimaryKey(Integer id);
    //根据id改变isdel的值
    int deleteById(Integer id);
    //根据添加考试
    void insertExam(ExamInfo examInfo);
    //查询所有试卷名称
    List<ExamPaper> findPaper();

    List<ExamType> findExamType();

    void updateById(ExamInfo examInfo);

    List<ExamUser> findAllUser();
}
